/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package org.ee.web;

import javax.faces.bean.ManagedBean;
import javax.faces.bean.ViewScoped;
import javax.faces.context.FacesContext;
import javax.servlet.http.HttpServletRequest;

/**
 *
 * @author Gabriel Bran <gbran.u@gmail.com>
 */
@ViewScoped
@ManagedBean
public class LoginBean implements java.io.Serializable {

    public void login() {
        try {
            ((HttpServletRequest)FacesContext.getCurrentInstance().getExternalContext().getRequest()).login("w", "w");
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
